package main

import (
	"errors"
	"fmt"
	"time"
)

func initConfig() (err error) {
	return errors.New("init config failed")
}

func test()  {
	defer func() {
		if err := recover();err !=nil{
			fmt.Println(err)
		}
	}()
	err := initConfig()
	if err != nil{
		fmt.Println(1)
		panic(err)
	}
}


func main()  {
	for{
		test()
		time.Sleep(time.Second)
	}
	var a []int
	a = append(a,10,20,30)
	fmt.Println(a)
	a = append(a,a...)
	fmt.Println(a)
}
